#!/usr/bin python3
# -*- coding:UTF-8 -*-
# Author: nigo
from multiprocess import Process
import time


def md2pdf(mdname, pdfname):
    time.sleep(5)
    print('%s转换完成' % mdname)


def work():
    for i in range(5):
        print(i)


if __name__ == '__main__':
    process = Process(target=md2pdf, args=('1.md', '1.pdf')) # 创建进程
    process.start() # 执行子进程
    process.join() # 阻塞当前进程
    work()
